import Vue from 'vue';
import Vuex from 'vuex';
const state = {
    level: ''
};
const getters = {};
const mutations = {
    saveLevel(state, level) {
        state.level = level
    }
};
const actions = {
    emitSaveLevel({
        commit
    }, level) {
        console.log(level);
        commit('saveLevel', level);
    }
};
// 声明使用插件
Vue.use(Vuex);
export default new Vuex.Store({
    state,
    getters,
    mutations,
    actions,
})